package face.pay.util.page;

import java.io.Serializable;
import java.util.List;

/**
 * @Description: (java类作用描述)
 * @Author: gpay
 * @CreateDate: 2018/11/16$ 13:22$
 * @UpdateUser:
 * @UpdateDate: 2018/11/16$ 13:22$
 * @UpdateRemark: 修改内容
 * @Version: 1.0
 */
public class PageData<T> implements Serializable {

    private Integer code = 1;

    private Long count;

    private List<T> data;


    private Long recordsTotal;

    private Long recordsFiltered;

    public Long getRecordsTotal() {
        return recordsTotal;
    }

    public void setRecordsTotal(Long recordsTotal) {
        this.recordsTotal = recordsTotal;
    }

    public Long getRecordsFiltered() {
        return recordsFiltered;
    }

    public void setRecordsFiltered(Long recordsFiltered) {
        this.recordsFiltered = recordsFiltered;
    }

    public PageData(){};

    public PageData(Long total, List list){
        this.count = total;
        this.data = list;
        this.recordsFiltered = total;
        this.recordsTotal=total;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public Long getCount() {
        return count;
    }

    public void setCount(Long count) {
        this.count = count;
    }

    public List<T> getData() {
        return data;
    }

    public void setData(List<T> data) {
        this.data = data;
    }

}
